package org.hank.demoproject

import android.os.Bundle
import android.view.LayoutInflater
import androidx.appcompat.app.AppCompatActivity
import androidx.databinding.DataBindingUtil
import androidx.databinding.ViewDataBinding
import androidx.viewbinding.ViewBinding
import github.nocamles.httphelper.base.BaseActivity

/**
 *@auth: Hank
 *邮箱: cs16xiaoc1@163.com
 *创建时间: 2023/4/17 15:50
 *描述:
 */
abstract class BaseViewBindingActivity<T : ViewBinding> : AppCompatActivity() {
    lateinit var viewBinding: T

    override fun onCreate(savedInstanceState: Bundle?) {
        super.onCreate(savedInstanceState)
        viewBinding = inflateLayout(layoutInflater)
        setContentView(viewBinding.root)
    }

    abstract fun inflateLayout(layoutInflater: LayoutInflater): T
}